﻿<UserControl x:Class="GitScc.UI.Loading"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             mc:Ignorable="d" 
             d:DesignHeight="80" d:DesignWidth="280">
    <Border Background="#84000000" CornerRadius="10" Height="80" Width="260">
        <StackPanel HorizontalAlignment="Center" VerticalAlignment="Center" Orientation="Horizontal">
            <Canvas Width="32" Height="32" Margin="10">
                <Canvas.Triggers>
                    <EventTrigger RoutedEvent="Canvas.Loaded">
                        <BeginStoryboard>
                            <Storyboard>
                                <DoubleAnimation From="0" To="360" RepeatBehavior="Forever" 
                                Storyboard.TargetName="spin" Storyboard.TargetProperty="(RotateTransform.Angle)" />
                            </Storyboard>
                        </BeginStoryboard>
                    </EventTrigger>
                </Canvas.Triggers>
                <Canvas.RenderTransform>
                    <RotateTransform x:Name="spin" Angle="0" CenterX="16" CenterY="16" />
                </Canvas.RenderTransform>
                <Image Source="/GitSccProvider;component/Resources/Loading.png" Width="32" Height="32" />
            </Canvas>

            <TextBlock Text="Analyzing Git repository ..." FontSize="12" Foreground="White" VerticalAlignment="Center" />

        </StackPanel>
    </Border>
</UserControl>
